{% extends "../../layui/layouts/main.html" %}

{% block mainbody %}
<div id="menu-index">

    <div class="layui-card">

        {% if newly > 0 %}
            <div class="layui-card-header" style="padding: 15px 15px 25px 15px;">
                <div class="alert-success">
                    当前有 <b style="color:red"> {{newly}}</b> 条新提交的药品上报风险！
                    <a href="/report-ready" style="color: blue">点击查看。</a>
                </div>
            </div>
        {% endif %}

        <div class="layui-card-body">

            <div class="layui-row layui-col-space15">
                <div class="layui-col-md4">
                    <div class="layui-card">
                        <div class="layui-card-body home-top-panel">
                            <h1>今日药品风险上报总数</h1>
                            <h1>{{daily.report}}</h1>
                        </div>
                    </div>
                </div>
                <div class="layui-col-md4">
                    <div class="layui-card">
                        <div class="layui-card-body home-top-panel">
                            <h1>历史药品风险上报总数</h1>
                            <h1>{{report.report}}</h1>
                        </div>
                    </div>
                </div>
                <div class="layui-col-md4">
                    <div class="layui-card">
                        <div class="layui-card-body home-top-panel">
                            <h1>已关注药品风险总数</h1>
                            <h1>{{report.watch}}</h1>
                        </div>
                    </div>
                </div>
            </div>

        </div>
    </div>

    <div class="layui-card">
        <div class="layui-card-header yak-card-header">
            待处理事务
        </div>
        <div class="layui-card-body">

            <div class="layui-row layui-col-space15">
                <div class="layui-col-md6">
                    <div class="layui-card">
                        <div class="layui-card-body home-middle-panel">
                            <h1>新提交药品风险 <small>{{newly}}</small></h1>
                        </div>
                    </div>
                </div>
                <div class="layui-col-md6">
                    <div class="layui-card">
                        <div class="layui-card-body home-middle-panel">
                            <h1>待处理药品风险 <small>{{report.report - report.watch - report.unwatch}}</small></h1>
                        </div>
                    </div>
                </div>
                <div class="layui-col-md6">
                    <div class="layui-card">
                        <div class="layui-card-body home-middle-panel">
                            <h1>今日已关注药品风险 <small>{{daily.watch}}</small></h1>
                        </div>
                    </div>
                </div>
                <div class="layui-col-md6">
                    <div class="layui-card">
                        <div class="layui-card-body home-middle-panel">
                            <h1>今日已处理药品风险 <small>{{daily.watch + daily.unwatch}}</small></h1>
                        </div>
                    </div>
                </div>
            </div>

        </div>
    </div>

</div>
{% endblock %}